<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="/common/common.jsp" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    
    <title>交费情况</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="交费,情况">
	<meta http-equiv="description" content="This is my page">
	
  </head>
  
  <body>
    <center>
    	<s:form name="frm" id="frm" method="post" action="queryPaySituationByThisMonth.action" namespace="/inner/common">
    		<s:hidden id="kindergartenId" name="kindergartenId"></s:hidden>
    		
    		<table cellspacing="1" cellpadding="3" width="100%" style="font-size:18px;">
    			<tr>
    				<td align="left" width="100px">当前日期：</td>
    				<td align="left">
    					<s:property value="today"/>
    				</td>
    			</tr>
    		</table>
    		
    		<table cellspacing="1" width="100%" bgcolor="#CCCCCC">
				<tr bgcolor="#FFFFFF">
					<td align="right" width="10%" class="label">
						姓名：
					</td>
					<td align="left" width="23%">
						<s:textfield name="childvo.child.childName" id="childName" cssStyle="width:80%" cssClass="search"></s:textfield>
					</td>
					<td align="right" width="10%" class="label">
						编号：
					</td>
					<td align="left" width="23%">
						<s:textfield name="childvo.child.childNum" id="childNum" cssStyle="width:80%" cssClass="search"></s:textfield>
					</td>
					<td align="right" width="10%" class="label">
						所属班级：
					</td>
					<td align="left" width="24%">
						<s:select name="childvo.classId" id="classId" value="%{childvo.classId}" list="classList" listKey="id" listValue="className" headerKey="" headerValue="--请选择--" cssStyle="width:120px" cssClass="search"></s:select>
					</td>
				</tr>
				<tr bgcolor="#FFFFFF">
					<td align="right" class="label">
						是否交费：
					</td>
					<td align="left" colspan="5">
						<s:select list='#{"N":"否", "Y":"是"}' name="childvo.hasPay" id="hasPay" cssStyle="width:80px" cssClass="search"></s:select>
					</td>
				</tr>
			</table>
    		
    		<table cellspacing="0" width="100%">
				<tr>
					<td align="left">
						<input type="button" value="查询" class="btn" onclick="searchThis()"/>
						<input type="button" value="重置" class="btn" onclick="toResetSearch()"/>
					</td>
				</tr>
			</table>
    		<table width="100%" cellspacing="1" cellpadding="3" bgcolor="#CCCCCC">
    			<tr class="tableHead" align="center">
    				<td width="10%">
    					序号
    				</td>
    				<td width="16%">
    					学童姓名
    				</td>
    				<td width="15%">
    					编号
    				</td>
    				<td width="10%">
    					性别
    				</td>
    				<td width="16%">
    					所属班级
    				</td>
    				<td width="18%">
    					入学日期
    				</td>
    				<td width="20%">
    					操作
    				</td>
    			</tr>
    			<s:iterator value="lp.list" status="s">
    				<tr align="center"
    					<s:if test="#s.index%2==0">class="tableRow2" onMouseMove="this.className='tableRow3'" onMouseOut="this.className='tableRow2'"</s:if>
						<s:else>class="tableRow1" onMouseMove="this.className='tableRow3'" onMouseOut="this.className='tableRow1'"</s:else>
    				>
    					<td>
    						<s:property value="(pager.thisPage - 1) * pager.pageSize + #s.index + 1" />
    					</td>
    					<td>
    						<s:property value="childName"/>
    					</td>
    					<td>
    						<s:property value="childNum"/>
    					</td>
    					<td>
    						<s:property value="sex"/>
    					</td>
    					<td>
    						<s:property value="className"/>
    					</td>
    					<td>
    						<s:date name="entranceTime" format="yyyy-MM-dd"/>
    					</td>
    					<td>
    						<a href="javascript:showThisMonthPay('<s:property value="id" />')">本月交费</a>
    					</td>
    				</tr>
    			</s:iterator>
    			<jsp:include page="/common/pager/pager.jsp">
					<jsp:param name="formName" value="frm" />
					<jsp:param name="id" value="1" />
				</jsp:include>
    		</table>
    	</s:form>
    </center>
    
    <script type="text/javascript">
	$(function(){
		var payFrame = parent.$('#payFrame');
		if(payFrame.length > 0)
		{
			payFrame.height($(document).height());
		}
	});
	
    function showThisMonthPay(id)
    {
    	var kgId = getTopKg();
    	var url = realPath + '/inner/charge/thisMonthPayList.action?childvo.child.id=' + id;
    	openWin(url, 700, 400, 'yes', 'yes');
    }
    
    function searchThis()
    {
    	$('#thisPage').val(1);
    	$('#frm').submit();
    }
    
    function toResetSearch()
    {
    	resetSearch();
    	var hasPay = $('#hasPay');
    	hasPay.val('N');
    }
    </script>
  </body>
</html>
